alias ls="ls --color=auto"
alias sr='screen -r'
alias grep='grep --color=auto'
alias ll='ls -l'
alias ssh-load="source $HOME/ssh-agent-`hostname`"
alias dirs="dirs -v"
alias p="pushd ."
alias trim="sed 's/^[ \t]*//;s/[ \t]*$//'"
alias vim="vim -O"
alias pp='python -mjson.tool'

## import local files
test -s ~/.bashrc.local && . ~/.bashrc.local || true

hgdiff() {
        vimdiff -c 'map q :xa!<CR>' <(hg cat "$1") "$1";
}

if [ -f $HOME/ssh-agent-`hostname` ]; then
  source $HOME/ssh-agent-`hostname` > /dev/null
fi

alias most="vim -R -"

if [ -e /usr/share/terminfo/x/xterm-256color ]; then
    export TERM='xterm-256color'
else
    export TERM='xterm-color'
fi
